package com.tuanzi.loan.web.lazy.credit;

import org.springframework.data.domain.Page;

import com.tuanzi.loan.business.service.credit.LoanCreditOrderStatService;
import com.tuanzi.loan.core.lazy.BaseLazyDataModel;
import com.tuanzi.loan.core.util.SpringContextHolder;
import com.tuanzi.loan.core.vo.PageSearcher;
import com.tuanzi.loan.vo.request.credit.LoanCreditOrderStatRequest;
import com.tuanzi.loan.vo.response.credit.LoanCreditOrderStatResponse;

public class LoanCreditOrderStatLazyDataModel extends BaseLazyDataModel<LoanCreditOrderStatRequest, LoanCreditOrderStatResponse> {

	private static final long serialVersionUID = -1530312269395678682L;
	
	private LoanCreditOrderStatService loanCreditOrderStatService = SpringContextHolder.getBean(LoanCreditOrderStatService.class);

	public LoanCreditOrderStatLazyDataModel(LoanCreditOrderStatRequest searchRequest) {
		super(searchRequest);
	}

	@Override
	protected Page<LoanCreditOrderStatResponse> doLoad(
			PageSearcher<LoanCreditOrderStatRequest> pageSearcher) {
		return loanCreditOrderStatService.list(pageSearcher);
	}

}
